package com.ruoyi.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import lombok.Data;

/**
 * 能源消费结构
 * @TableName ny5
 */
@TableName(value ="ny5")
@Data
public class Ny5 implements Serializable {
    /**
     * 
     */
    @TableId(type = IdType.AUTO)
    private Integer id;

    /**
     * 能源类型
     */
    private String ny;

    /**
     * 消费规模（总消费量/万吨）
     */
    private Long xfgm5;

    /**
     * 消费结构（工业/交通/居民）
     */
    private String xfjg5;

    /**
     * 消费趋势
     */
    private Long xfqs5;

    /**
     * 消费地域
     */
    private String xfdy5;

    /**
     * 能源利用率
     */
    private Long nyyxfxl5;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Ny5 other = (Ny5) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getNy() == null ? other.getNy() == null : this.getNy().equals(other.getNy()))
            && (this.getXfgm5() == null ? other.getXfgm5() == null : this.getXfgm5().equals(other.getXfgm5()))
            && (this.getXfjg5() == null ? other.getXfjg5() == null : this.getXfjg5().equals(other.getXfjg5()))
            && (this.getXfqs5() == null ? other.getXfqs5() == null : this.getXfqs5().equals(other.getXfqs5()))
            && (this.getXfdy5() == null ? other.getXfdy5() == null : this.getXfdy5().equals(other.getXfdy5()))
            && (this.getNyyxfxl5() == null ? other.getNyyxfxl5() == null : this.getNyyxfxl5().equals(other.getNyyxfxl5()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getNy() == null) ? 0 : getNy().hashCode());
        result = prime * result + ((getXfgm5() == null) ? 0 : getXfgm5().hashCode());
        result = prime * result + ((getXfjg5() == null) ? 0 : getXfjg5().hashCode());
        result = prime * result + ((getXfqs5() == null) ? 0 : getXfqs5().hashCode());
        result = prime * result + ((getXfdy5() == null) ? 0 : getXfdy5().hashCode());
        result = prime * result + ((getNyyxfxl5() == null) ? 0 : getNyyxfxl5().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", ny=").append(ny);
        sb.append(", xfgm5=").append(xfgm5);
        sb.append(", xfjg5=").append(xfjg5);
        sb.append(", xfqs5=").append(xfqs5);
        sb.append(", xfdy5=").append(xfdy5);
        sb.append(", nyyxfxl5=").append(nyyxfxl5);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}